
// It's generated file. DO NOT MODIFY IT!

using Diablerie.Engine.Datasheets;
using Diablerie.Engine.IO.D2Formats;

class MonStatLoader : Datasheet.Loader<MonStat>
{
    private MonStatStatsLoader monstatstatsloader = new MonStatStatsLoader();
    private MonStatTreasureClassInfoLoader monstattreasureclassinfoloader = new MonStatTreasureClassInfoLoader();

    public void LoadRecord(ref MonStat record, DatasheetStream stream)
    {
                stream.Read(ref record.id);
                stream.Read(ref record.hcIndex);
                stream.Read(ref record.baseId);
                stream.Read(ref record.nextInClass);
                stream.Read(ref record.transLvl);
                stream.Read(ref record.nameStr);
                stream.Read(ref record.monStatEx);
                stream.Read(ref record.monProp);
                stream.Read(ref record.monType);
                stream.Read(ref record.ai);
                stream.Read(ref record.descStr);
                stream.Read(ref record.code);
                stream.Read(ref record.enabled);
                stream.Read(ref record.rangedType);
                stream.Read(ref record.placeSpawn);
                stream.Read(ref record.spawn);
                stream.Read(ref record.spawnX);
                stream.Read(ref record.spawnY);
                stream.Read(ref record.spawnMode);
                stream.Read(ref record.minion1Id);
                stream.Read(ref record.minion2Id);
                stream.Read(ref record.SetBoss);
                stream.Read(ref record.BossXfer);
                stream.Read(ref record.partyMin);
                stream.Read(ref record.partyMax);
                stream.Read(ref record.minGrp);
                stream.Read(ref record.maxGrp);
                stream.Read(ref record.sparsePopulate);
                stream.Read(ref record.speed);
                stream.Read(ref record.runSpeed);
                stream.Read(ref record.Rarity);
                record.level = new int[3];
                    stream.Read(ref record.level[0]);
                    stream.Read(ref record.level[1]);
                    stream.Read(ref record.level[2]);
                stream.Read(ref record.monSoundId);
                stream.Read(ref record.uMonSoundId);
                stream.Read(ref record.threat);
                record.aidel = new int[3];
                    stream.Read(ref record.aidel[0]);
                    stream.Read(ref record.aidel[1]);
                    stream.Read(ref record.aidel[2]);
                record.aidist = new int[3];
                    stream.Read(ref record.aidist[0]);
                    stream.Read(ref record.aidist[1]);
                    stream.Read(ref record.aidist[2]);
                record.aip1 = new int[24];
                    stream.Read(ref record.aip1[0]);
                    stream.Read(ref record.aip1[1]);
                    stream.Read(ref record.aip1[2]);
                    stream.Read(ref record.aip1[3]);
                    stream.Read(ref record.aip1[4]);
                    stream.Read(ref record.aip1[5]);
                    stream.Read(ref record.aip1[6]);
                    stream.Read(ref record.aip1[7]);
                    stream.Read(ref record.aip1[8]);
                    stream.Read(ref record.aip1[9]);
                    stream.Read(ref record.aip1[10]);
                    stream.Read(ref record.aip1[11]);
                    stream.Read(ref record.aip1[12]);
                    stream.Read(ref record.aip1[13]);
                    stream.Read(ref record.aip1[14]);
                    stream.Read(ref record.aip1[15]);
                    stream.Read(ref record.aip1[16]);
                    stream.Read(ref record.aip1[17]);
                    stream.Read(ref record.aip1[18]);
                    stream.Read(ref record.aip1[19]);
                    stream.Read(ref record.aip1[20]);
                    stream.Read(ref record.aip1[21]);
                    stream.Read(ref record.aip1[22]);
                    stream.Read(ref record.aip1[23]);
                stream.Read(ref record.MissA1);
                stream.Read(ref record.MissA2);
                stream.Read(ref record.MissS1);
                stream.Read(ref record.MissS2);
                stream.Read(ref record.MissS3);
                stream.Read(ref record.MissS4);
                stream.Read(ref record.MissC);
                stream.Read(ref record.MissSQ);
                stream.Read(ref record.Align);
                stream.Read(ref record.isSpawn);
                stream.Read(ref record.isMelee);
                stream.Read(ref record.npc);
                stream.Read(ref record.interact);
                stream.Read(ref record.inventory);
                stream.Read(ref record.inTown);
                stream.Read(ref record.lUndead);
                stream.Read(ref record.hUndead);
                stream.Read(ref record.demon);
                stream.Read(ref record.flying);
                stream.Read(ref record.opendoors);
                stream.Read(ref record.boss);
                stream.Read(ref record.primeevil);
                stream.Read(ref record.killable);
                stream.Read(ref record.switchai);
                stream.Read(ref record.noAura);
                stream.Read(ref record.nomultishot);
                stream.Read(ref record.neverCount);
                stream.Read(ref record.petIgnore);
                stream.Read(ref record.deathDmg);
                stream.Read(ref record.genericSpawn);
                stream.Read(ref record.zoo);
                stream.Read(ref record.SendSkills);
                stream.Read(ref record.Skill1);
                stream.Read(ref record.Sk1mode);
                stream.Read(ref record.Sk1lvl);
                record.remainingSkillsInfo = new string[21];
                    stream.Read(ref record.remainingSkillsInfo[0]);
                    stream.Read(ref record.remainingSkillsInfo[1]);
                    stream.Read(ref record.remainingSkillsInfo[2]);
                    stream.Read(ref record.remainingSkillsInfo[3]);
                    stream.Read(ref record.remainingSkillsInfo[4]);
                    stream.Read(ref record.remainingSkillsInfo[5]);
                    stream.Read(ref record.remainingSkillsInfo[6]);
                    stream.Read(ref record.remainingSkillsInfo[7]);
                    stream.Read(ref record.remainingSkillsInfo[8]);
                    stream.Read(ref record.remainingSkillsInfo[9]);
                    stream.Read(ref record.remainingSkillsInfo[10]);
                    stream.Read(ref record.remainingSkillsInfo[11]);
                    stream.Read(ref record.remainingSkillsInfo[12]);
                    stream.Read(ref record.remainingSkillsInfo[13]);
                    stream.Read(ref record.remainingSkillsInfo[14]);
                    stream.Read(ref record.remainingSkillsInfo[15]);
                    stream.Read(ref record.remainingSkillsInfo[16]);
                    stream.Read(ref record.remainingSkillsInfo[17]);
                    stream.Read(ref record.remainingSkillsInfo[18]);
                    stream.Read(ref record.remainingSkillsInfo[19]);
                    stream.Read(ref record.remainingSkillsInfo[20]);
                record.drain = new string[3];
                    stream.Read(ref record.drain[0]);
                    stream.Read(ref record.drain[1]);
                    stream.Read(ref record.drain[2]);
                record.coldEffect = new string[3];
                    stream.Read(ref record.coldEffect[0]);
                    stream.Read(ref record.coldEffect[1]);
                    stream.Read(ref record.coldEffect[2]);
                stream.Read(ref record.ResDm);
                stream.Read(ref record.ResMa);
                stream.Read(ref record.ResFi);
                stream.Read(ref record.ResLi);
                stream.Read(ref record.ResCo);
                stream.Read(ref record.ResPo);
                record.remainingResInfo = new string[12];
                    stream.Read(ref record.remainingResInfo[0]);
                    stream.Read(ref record.remainingResInfo[1]);
                    stream.Read(ref record.remainingResInfo[2]);
                    stream.Read(ref record.remainingResInfo[3]);
                    stream.Read(ref record.remainingResInfo[4]);
                    stream.Read(ref record.remainingResInfo[5]);
                    stream.Read(ref record.remainingResInfo[6]);
                    stream.Read(ref record.remainingResInfo[7]);
                    stream.Read(ref record.remainingResInfo[8]);
                    stream.Read(ref record.remainingResInfo[9]);
                    stream.Read(ref record.remainingResInfo[10]);
                    stream.Read(ref record.remainingResInfo[11]);
                stream.Read(ref record.DamageRegen);
                stream.Read(ref record.skillDamage);
                stream.Read(ref record.noRatio);
                stream.Read(ref record.NoShldBlock);
                record.toBlock = new string[3];
                    stream.Read(ref record.toBlock[0]);
                    stream.Read(ref record.toBlock[1]);
                    stream.Read(ref record.toBlock[2]);
                stream.Read(ref record.Crit);
                record.stats = new MonStat.Stats[3];
                    monstatstatsloader.LoadRecord(ref record.stats[0], stream);
                    monstatstatsloader.LoadRecord(ref record.stats[1], stream);
                    monstatstatsloader.LoadRecord(ref record.stats[2], stream);
                record.elementalDamage = new string[42];
                    stream.Read(ref record.elementalDamage[0]);
                    stream.Read(ref record.elementalDamage[1]);
                    stream.Read(ref record.elementalDamage[2]);
                    stream.Read(ref record.elementalDamage[3]);
                    stream.Read(ref record.elementalDamage[4]);
                    stream.Read(ref record.elementalDamage[5]);
                    stream.Read(ref record.elementalDamage[6]);
                    stream.Read(ref record.elementalDamage[7]);
                    stream.Read(ref record.elementalDamage[8]);
                    stream.Read(ref record.elementalDamage[9]);
                    stream.Read(ref record.elementalDamage[10]);
                    stream.Read(ref record.elementalDamage[11]);
                    stream.Read(ref record.elementalDamage[12]);
                    stream.Read(ref record.elementalDamage[13]);
                    stream.Read(ref record.elementalDamage[14]);
                    stream.Read(ref record.elementalDamage[15]);
                    stream.Read(ref record.elementalDamage[16]);
                    stream.Read(ref record.elementalDamage[17]);
                    stream.Read(ref record.elementalDamage[18]);
                    stream.Read(ref record.elementalDamage[19]);
                    stream.Read(ref record.elementalDamage[20]);
                    stream.Read(ref record.elementalDamage[21]);
                    stream.Read(ref record.elementalDamage[22]);
                    stream.Read(ref record.elementalDamage[23]);
                    stream.Read(ref record.elementalDamage[24]);
                    stream.Read(ref record.elementalDamage[25]);
                    stream.Read(ref record.elementalDamage[26]);
                    stream.Read(ref record.elementalDamage[27]);
                    stream.Read(ref record.elementalDamage[28]);
                    stream.Read(ref record.elementalDamage[29]);
                    stream.Read(ref record.elementalDamage[30]);
                    stream.Read(ref record.elementalDamage[31]);
                    stream.Read(ref record.elementalDamage[32]);
                    stream.Read(ref record.elementalDamage[33]);
                    stream.Read(ref record.elementalDamage[34]);
                    stream.Read(ref record.elementalDamage[35]);
                    stream.Read(ref record.elementalDamage[36]);
                    stream.Read(ref record.elementalDamage[37]);
                    stream.Read(ref record.elementalDamage[38]);
                    stream.Read(ref record.elementalDamage[39]);
                    stream.Read(ref record.elementalDamage[40]);
                    stream.Read(ref record.elementalDamage[41]);
                record.treasureClass = new MonStat.TreasureClassInfo[3];
                    monstattreasureclassinfoloader.LoadRecord(ref record.treasureClass[0], stream);
                    monstattreasureclassinfoloader.LoadRecord(ref record.treasureClass[1], stream);
                    monstattreasureclassinfoloader.LoadRecord(ref record.treasureClass[2], stream);
                stream.Read(ref record.TCQuestId);
                stream.Read(ref record.TCQuestCP);
                stream.Read(ref record.SplEndDeath);
                stream.Read(ref record.SplGetModeChart);
                stream.Read(ref record.SplEndGeneric);
                stream.Read(ref record.SplClientEnd);
                stream.Read(ref record.eol);
    }
}
